package com.chey.dao;

import com.chey.pojo.META;
import com.chey.pojo.stls.DFLT;
import com.chey.pojo.stls.STND;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

/**
 * @author JanYao
 * @version 0.1
 */
public interface StlsDao {
    @Select("insert into META(META_ID,SENDER,RECEIVER,SEQUENCE,DTIME,MTYPE,STYPE) " +
            "values(#{uuid},#{meta.sender},#{meta.receiver},#{meta.sequence},#{meta.dTime},#{meta.bType},#{meta.sType})")
    public Integer addMeta(@Param("uuid") String uuid, @Param("meta") META meta);

@Select("insert into MSG_DFME_STLS " +
        "values(#{dflt.FLID}, #{dflt.FFID}, #{dflt.FIDE}, #{dflt.FATT},#{uuid},#{uuid})")
    public Integer addDflt(@Param("uuid") String uuid, @Param("dflt") DFLT dflt);

    @Select("insert into DFME_STLS_STND " +
            "values(#{uuid},#{stnd.STNO}, #{stnd.CODE}, #{stnd.ESTR}, #{stnd.EEND}, #{stnd.RSTR}, #{stnd.REND}, #{stnd.CSSI}, #{stnd.BTSC})")
    public Integer addStnd(@Param("uuid") String uuid, @Param("stnd") STND stnd);
}
